<?php

namespace App\Http\Controllers;

use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Routing\Controller as BaseController;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;

class Controller extends BaseController
{
    use AuthorizesRequests, DispatchesJobs, ValidatesRequests;

	/**
	 * [延时重定向]
	 * @param $msg 	string
	 * @param $url 	string
	 * @param $type = ['danger','success','primary','info','warning']
	 */
	public function redirectWithMsg($msg,$url,$type="primary",$title="提示") {
		return view('msg_page',[
			"MSG" => $msg,
			"URL" => $url,
			"TYPE" => $type,
			"TITLE" => $title
		]);
	}
}
